package cn.stylefeng.guns.sys.modular.system.entity.Enum;

import lombok.Getter;

@Getter
public enum WxMsgPushEnum {
    STATUS_TOPUSH(0, "待推送"),
    STATUS_PUSHED(1, "已推送"),
    RESULT_SUC(1, "发送成功"),
    RESULT_FAILED(0, "发送失败"),
    BUSINESS_TYPE(1, "工程"),
    TEMPLATE_GC(0, "GvxDqRmFMg41dT9-0ndOF6oh8_XW_Vcx0mXO04m6PNQ"),
//    STATUS_TOPUSH(0, "待推送"),
//    STATUS_PUSHED(1, "已推送"),
    ;

    WxMsgPushEnum(Integer code, String value) {
        this.code = code;
        this.value = value;
    }

    private Integer code;

    private String value;

    public static WxMsgPushEnum getByCode(Integer value){
        for(WxMsgPushEnum transactType : values()){
            if (transactType.getCode().equals(value)) {
                return transactType;
            }
        }
        return null;
    }

}
